# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

inherit subversion eutils 

ESVN_REPO_URI="http://ggobi.org/svn/ggobi/ggobi/trunk"
ESVN_PROJECT="ggobi"
#ECVS_SERVER="cvs.sourceforge.net:/cvsroot/nogravity"
#ECVS_MODULE="nogravity"
#ECVS_LOCALNAME="nogravity"
S=${WORKDIR}


DESCRIPTION="No Gravity Game"
HOMEPAGE="http://sf.net/"
LICENSE="GPL"
SLOT="0"
KEYWORDS="~x86 ~amd64 ~ppc"
DEPEND=""

src_unpack() {
#	svn_src_unpack
	subversion_src_unpack
#	cd ${WORKDIR}/M
	cd $S/trunk	
#	epatch ${FILESDIR}/r200-copy-pixels-1.patch

#	cd ${WORKDIR}/xgl-xorg
#	epatch ${FILESDIR}/xgl-slang-library-noise.diff
}

src_compile() {
	use amd64
	cd $S/trunk
	./bootstrap
	#econf || die
	./configure --host=${CHOST} \
	--prefix=/usr \
	--libdir=/usr/$(get_libdir) \
	--infodir=/usr/share/info \
	--mandir=/usr/share/man \
	--with-fontdir=/usr/share/fonts \
	--enable-local || die
	--with-plugins="DataViewer GraphAction GraphLayout ggvis VarCloud DescribeDisplay" \
	#--enable-debug ||die
	#--enable-sound=sdl_mixer || die
	# --enable-xkb
	make || die "emake failed"
}

src_install() {
	cd $S/trunk
	#make DESTDIR=${D} install || die
	einstall || die
}
